<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>

<body>

</body>

</html>
<script type="text/javascript"
  src="http://webapi.amap.com/maps?v=1.3&key=3f106cab686aa907fae5d023cca93351&plugin=AMap.Driving,AMap.MouseTool,AMap.PolyEditor,AMap.ToolBar"></script>
<script type="text/javascript" src="http://cache.amap.com/lbs/static/DrivingRender1230.js"></script>
<script type="text/javascript" src="http://cache.amap.com/lbs/static/addToolbar.js"></script>
<script>

  /*
   *根据经纬度计算打卡地点是否在范围内：
    latitude
  : 
  34.7471
  longitude
  : 
  113.6253
  范围：300m,圆
  */
  var longitude = 113.6253;
  var latitude = 34.7471;
  var radius = 300;
  var map = new AMap.Map("container", {
    center: [longitude, latitude],
    zoom: 14
  });
  function computed(lon, lat, r) {
    var circle = new AMap.Circle({
      center: [lon, lat],
      radius: r, //半径 m
    })
    var myLngLat = new AMap.LngLat(lon, lat);
    return circle.contains(myLngLat)
  }
  var addressStatus = computed(longitude, latitude, radius)
  console.log('c', addressStatus)
</script>